# 书名打印，书名超过五位则用...表示
ming = ['莫泊桑中短篇小说选','神秘岛','最后一课','钢铁是怎样炼成的','契诃夫短篇小说选'
        ,'绿野仙踪','汤姆·索亚历险记','百万英镑','简·爱']
a=[]
# 循环遍历列表
for i in ming:
    if len(i)>5:
        a.append(i[:5]+'...')
    else:
        a.append(i)
print(','.join(a))
    # for j in range(len(i)):
    #     if j > 4:
    #         print('.',end='')
    #     else:
    #         print(i[j],end='')
    # print()

    